<script type="text/javascript">
function logout(){
	$.dialog.confirm('你确定要退出？', function(){
	    $.ajax({
			url:'<!--{U str="admin/public/logout"}-->',
			type:'get',
			success:function(data){
				if(data.result){
					window.location.href = data.data.url;
				}
			}
		});
	}, function(){
	    $.dialog.tips('执行取消操作');
	});
}
function clearCache(){
	$.dialog.confirm('清除页面缓存？', function(){
	    $.ajax({
			url:'<!--{U str="admin/public/clearCache"}-->',
			type:'get'
		});
	}, function(){
	    $.dialog.tips('执行取消操作');
	});
}

function changePassword(){
	$.dialog({
	    width: '550px',
	    height: '300px',
	    title:'修改密码',
	    content: 'url:<!--{U str="admin/setting/changePassword"}-->',
	});
}
</script>
<h1 class="logo"><a href="<!--{U str='admin/index/home'}-->" title="CXNET Admin" target="myframe">SimpleCMS Admin</a></h1>
<div class="mainnav">
</div>
<div class="user_info">
  <ul class="nav nav-pills pull-right">
    <li class="dropdown" id="menu1"> <a class="dropdown-toggle" data-toggle="dropdown" href="#menu1"> <i class="icon-user"></i><!--{$username}--><b class="caret"></b> </a>
      <ul class="dropdown-menu">
        <li><a href="<!--{U str='admin/index/home'}-->" target="myframe">管理后台首页</a></li>
        <li><a href="javascript:;" onclick="changePassword()">修改密码</a></li>
        <li><a href="javascript:;" onclick="clearCache()">清理缓存</a></li>
        <li class="divider"></li>
        <li><a href="javascript:;" onclick="logout()">退出</a></li>
      </ul>
    </li>
  </ul>
</div>
